Integrand size = 19, antiderivative size = 115 \[ \int \csc (c+d x) (a+b \sec (c+d x))^n \, dx=\frac {\operatorname {Hypergeometric2F1}\left (1,1+n,2+n,\frac {a+b \sec (c+d x)}{a-b}\right ) (a+b \sec (c+d x))^{1+n}}{2 (a-b) d (1+n)}-\frac {\operatorname {Hypergeometric2F1}\left (1,1+n,2+n,\frac {a+b \sec (c+d x)}{a+b}\right ) (a+b \sec (c+d x))^{1+n}}{2 (a+b) d (1+n)} \]
1/2*hypergeom([1, 1+n],[2+n],(a+b*sec(d*x+c))/(a-b))*(a+b*sec(d*x+c))^(1+n )/(a-b)/d/(1+n)-1/2*hypergeom([1, 1+n],[2+n],(a+b*sec(d*x+c))/(a+b))*(a+b* sec(d*x+c))^(1+n)/(a+b)/d/(1+n)
Time = 1.10 (sec) , antiderivative size = 132, normalized size of antiderivative = 1.15 \[ \int \csc (c+d x) (a+b \sec (c+d x))^n \, dx=\frac {\left (\operatorname {Hypergeometric2F1}\left (1,-n,1-n,\frac {(a+b) \cos (c+d x)}{b+a \cos (c+d x)}\right )-2^n \operatorname {Hypergeometric2F1}\left (-n,-n,1-n,\frac {(-a+b) \cos (c+d x) \sec ^2\left (\frac {1}{2} (c+d x)\right )}{2 b}\right ) \left (\frac {(b+a \cos (c+d x)) \sec ^2\left (\frac {1}{2} (c+d x)\right )}{b}\right )^{-n}\right ) (a+b \sec (c+d x))^n}{2 d n} \]
((Hypergeometric2F1[1, -n, 1 - n, ((a + b)*Cos[c + d*x])/(b + a*Cos[c + d* x])] - (2^n*Hypergeometric2F1[-n, -n, 1 - n, ((-a + b)*Cos[c + d*x]*Sec[(c + d*x)/2]^2)/(2*b)])/(((b + a*Cos[c + d*x])*Sec[(c + d*x)/2]^2)/b)^n)*(a + b*Sec[c + d*x])^n)/(2*d*n)
Time = 0.31 (sec) , antiderivative size = 114, normalized size of antiderivative = 0.99, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.316, Rules used = {3042, 4362, 25, 82, 485, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \csc (c+d x) (a+b \sec (c+d x))^n \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\left (a-b \csc \left (c+d x-\frac {\pi }{2}\right )\right )^n}{\cos \left (c+d x-\frac {\pi }{2}\right )}dx\) |
\(\Big \downarrow \) 4362 |
\(\displaystyle -\frac {\int -\frac {(a+b \sec (c+d x))^n}{(1-\sec (c+d x)) (\sec (c+d x)+1)}d(-\sec (c+d x))}{d}\) |
\(\Big \downarrow \) 25 |
\(\displaystyle \frac {\int \frac {(a+b \sec (c+d x))^n}{(1-\sec (c+d x)) (\sec (c+d x)+1)}d(-\sec (c+d x))}{d}\) |
\(\Big \downarrow \) 82 |
\(\displaystyle \frac {\int \frac {(a+b \sec (c+d x))^n}{1-\sec ^2(c+d x)}d(-\sec (c+d x))}{d}\) |
\(\Big \downarrow \) 485 |
\(\displaystyle \frac {\int \left (\frac {(a+b \sec (c+d x))^n}{2 (1-\sec (c+d x))}+\frac {(a+b \sec (c+d x))^n}{2 (\sec (c+d x)+1)}\right )d(-\sec (c+d x))}{d}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {\frac {(a+b \sec (c+d x))^{n+1} \operatorname {Hypergeometric2F1}\left (1,n+1,n+2,\frac {a+b \sec (c+d x)}{a+b}\right )}{2 (n+1) (a+b)}-\frac {(a+b \sec (c+d x))^{n+1} \operatorname {Hypergeometric2F1}\left (1,n+1,n+2,\frac {a+b \sec (c+d x)}{a-b}\right )}{2 (n+1) (a-b)}}{d}\) |
-((-1/2*(Hypergeometric2F1[1, 1 + n, 2 + n, (a + b*Sec[c + d*x])/(a - b)]* (a + b*Sec[c + d*x])^(1 + n))/((a - b)*(1 + n)) + (Hypergeometric2F1[1, 1 + n, 2 + n, (a + b*Sec[c + d*x])/(a + b)]*(a + b*Sec[c + d*x])^(1 + n))/(2 *(a + b)*(1 + n)))/d)
3.3.71.3.1 Defintions of rubi rules used
Int[((a_) + (b_.)*(x_))^(m_.)*((c_) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_) )^(p_.), x_] :> Int[(a*c + b*d*x^2)^m*(e + f*x)^p, x] /; FreeQ[{a, b, c, d, e, f, m, n, p}, x] && EqQ[b*c + a*d, 0] && EqQ[n, m] && IntegerQ[m]
Int[((c_) + (d_.)*(x_))^(n_)/((a_) + (b_.)*(x_)^2), x_Symbol] :> Int[Expand Integrand[(c + d*x)^n, 1/(a + b*x^2), x], x] /; FreeQ[{a, b, c, d, n}, x] & & !IntegerQ[2*n]
Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m _), x_Symbol] :> Simp[-f^(-1) Subst[Int[(-1 + x)^((p - 1)/2)*(1 + x)^((p - 1)/2)*((a + b*x)^m/x^(p + 1)), x], x, Csc[e + f*x]], x] /; FreeQ[{a, b, e , f, m}, x] && IntegerQ[(p - 1)/2] && NeQ[a^2 - b^2, 0]
\[\int \csc \left (d x +c \right ) \left (a +b \sec \left (d x +c \right )\right )^{n}d x\]
\[ \int \csc (c+d x) (a+b \sec (c+d x))^n \, dx=\int { {\left (b \sec \left (d x + c\right ) + a\right )}^{n} \csc \left (d x + c\right ) \,d x } \]
\[ \int \csc (c+d x) (a+b \sec (c+d x))^n \, dx=\int \left (a + b \sec {\left (c + d x \right )}\right )^{n} \csc {\left (c + d x \right )}\, dx \]
\[ \int \csc (c+d x) (a+b \sec (c+d x))^n \, dx=\int { {\left (b \sec \left (d x + c\right ) + a\right )}^{n} \csc \left (d x + c\right ) \,d x } \]
\[ \int \csc (c+d x) (a+b \sec (c+d x))^n \, dx=\int { {\left (b \sec \left (d x + c\right ) + a\right )}^{n} \csc \left (d x + c\right ) \,d x } \]
Timed out. \[ \int \csc (c+d x) (a+b \sec (c+d x))^n \, dx=\int \frac {{\left (a+\frac {b}{\cos \left (c+d\,x\right )}\right )}^n}{\sin \left (c+d\,x\right )} \,d x \]